package exer;

import java.util.Timer;
import java.util.TimerTask;

/**
 * @author tongchen
 * @create 2023-01-14 14:02
 */
public class TimerTest {
    public static void main(String[] args) {
        byte byt=(byte) 129;
        System.out.println(byt);
        Timer timer = new Timer();
        timer.schedule(new TimerTask() {
            @Override
            public void run() {
                System.out.println("执行任务1");
            }
        }, 3000);
        timer.schedule(new TimerTask() {
            @Override
            public void run() {
                System.out.println("执行任务2");
            }
        }, 4000);
        timer.schedule(new TimerTask() {
            @Override
            public void run() {
                System.out.println("执行任务3");
            }
        }, 5000);

    }
}
